Prediction-Correction Approach to Zero Shot Learning

ABSTRACT

Approaches to zero-shot learning include partitioning training data into first and second sets according to classes assigned to the training data, training a prediction module based on the first set to predict a cluster center based on a class label, training a correction module based on the second set and each of the class labels in the first set to generate a correction to a cluster center predicted by the prediction module, presenting a new class label for a new class to the prediction module to predict a new cluster center, presenting the new class label, the predicted new cluster center, and each of the class labels in the first set to the correction module to generate a correction for the predicted new cluster center, augmenting a classifier based on the corrected cluster center for the new class, and classifying input data into the new class using the classifier.

RELATED APPLICATIONS

The present application claims priority to U.S. Provisional PatentApplication No. 62/737,805, filed Sep. 27, 2018, entitled“Prediction-Correction Approach to Zero Shot Learning,” which is herebyincorporated by reference in its entirety.

TECHNICAL FIELD

The present disclosure relates generally to classification and morespecifically to using a prediction-correction approach to provide zeroshot learning to a classifier.

BACKGROUND

Classifiers are often used in intelligent systems to receive an exampleinput, such as an image, analyze the input, and then classify the inputinto one of a predetermined number of classes. A common approach inclassifier development is to supply a set of training data that includesexamples of input from each of the classes and a ground truthclassification for each of the input examples. The training data is thenpresented to a deep learning system, such as a neural network, and thedeep learning system is trained to recognize the classes by correctingits classification, such as using the stochastic gradient descentlearning algorithm and/or back propagation.

Classifiers developed in this way typically generalize poorly because,even though they are able to fairly accurately classify to the trainedclasses, they are not able to classify to a new class. Additionalclasses can be added to the classifier, but this generally requires thedeep learning system to be retrained in order to recognize theadditional classes. In other words, the deep learning system is not ableto extrapolate from its initial training without undergoing furthertraining.

Accordingly, it would be advantageous to have classifiers for which itis possible to add new classes without having to retrain the classifier.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a simplified diagram of a computing device according to someembodiments.

FIG. 2 is a simplified diagram of a method for zero shot learning usinga prediction-correction approach according to some embodiments.

FIG. 3A is a simplified diagram of a prediction module during trainingaccording to some embodiments.

FIG. 3B is a simplified diagram of a correction module during trainingaccording to some embodiments.

FIG. 4 is a simplified diagram of a classification system during useaccording to some embodiments.

FIG. 5 is a simplified diagram of training data for a class according tosome embodiments.

FIG. 6 is a simplified diagram of classification accuracy against datafrom new classes according to some embodiments.

FIG. 7 is a simplified diagram of classification accuracy against datafrom both trained and new classes according to some embodiments.

FIG. 8 is a simplified diagram of the impact of various factors onclassification accuracy according to some embodiments.

In the figures, elements having the same designations have the same orsimilar functions.

DETAILED DESCRIPTION

Image classifiers are classifiers that are designed to receive an image,analyze the content of the image, and then classify the content of theimage into one of a predefined set of classes. A common approach toimage classifiers is to use a deep learning system based classifier thatis trained by showing the classifier a large number of training imagesfor which the correct (e.g., ground truth) classification is known andproviding feedback (e.g., via a stochastic gradient descent algorithmusing back propagation) during the training. Once the classifier istrained, it is generally able to correctly classify new images from thetrained class. In some embodiments, the classifier works by extractingrelevant features from each image and maps them to a feature vectorspace where images from the same class generally cluster around a sameregion in the feature vector space that may be defined by a clustercenter based on an aggregation of the feature vectors for each of thetraining samples. When an image is presented to the classifier, itanalyzes the image and generates a feature vector, which may beclassified into the class whose cluster center is closest to the featurevector.

However, the classifier is generally poor at correctly classifying theimages from an untrained class as it does not generalize well because ithas not been trained to extrapolate from its training to identify thenew class (e.g., because it has not learned a corresponding clustercenter for the new class). Often, the classifier is only able toindicate that an image from the new class does not match any of thetrained classes (e.g., because its feature vector is farther than athreshold distance from any of the learned cluster centers). The newclass can be added to the classifier, but this generally requires thatthe classifier be retrained using training data that includes a numberof training samples from the new class.

According to some embodiments, use of class descriptions (e.g., classlabels) to describe classes in addition to image samples in the trainingdata provides for a more robust classifier as the classifier can betrained to recognize images from the trained classes based onobservations that the images match the features described in the classdescriptions. In addition, describing classes with descriptions alsosupports zero-shot learning (e.g., learning without express training) asit is much easier to extrapolate a new class based on a description ofthe new class rather than in the isolation of a new image from the newclass.

Natural language is a natural and intuitive medium for humans to conveyinformation that describes a class. Natural language is particularlyuseful for people with little machine learning background to shareknowledge. For example, in fine-grained classification of bird species,bird experts are able to use their knowledge to select what areconsidered different species, why similar birds are considered differentspecies and to articulate this knowledge via a natural language-baseddescription that others are able to use to recognize a new specieswithout first having to be trained based on images of the new species.In addition, by using natural language as an input format, the birdexpert, as an example, does not need prerequisite machine learningknowledge in order to augment an existing bird classification system.Additionally, defining classes using descriptions mimics how humansteach and learn to differentiate between fine-grained classes andacquire domain knowledge.

According to some embodiments, one approach that takes advantage ofclass descriptions is to train a deep learning prediction module that isable to receive a new class description and predict a new cluster centerfor that new class. The new cluster center can then be added to the setof cluster centers used by the classifier to give the classifier theability to classify images from the new class as belonging to the newclass. However, the prediction module may suffer from the same types oflimited ability to generalize and/or extrapolate from the classdescriptions used during training.

According to some embodiments, a prediction-correction approach todetermining the cluster center for the new class is likely to be morerobust at extrapolating to determine the new cluster center. Theprediction-correction approach works by partitioning the training datainto a set of prediction classes used to train the prediction module anda separate set of correction classes used to train the correctionmodule. Because the correction module is trained to extrapolate to theset of correction classes, which are separate from the set of predictionclasses used to train the prediction module, the correction module isable to provide a better prediction as to the correct cluster centerwhen an entirely new class description is provided. In some examples,the correction module is able to recognize differences between classdescriptions and is thus able to provide a corresponding correction to aprediction for the new class made by the prediction module that is basedon how significant those differences are.

FIG. 1 is a simplified diagram of a computing device 100 according tosome embodiments. As shown in FIG. 1, computing device 100 includes aprocessor 110 coupled to memory 120. Operation of computing device 100is controlled by processor 110. And although computing device 100 isshown with only one processor 110, it is understood that processor 110may be representative of one or more central processing units,multi-core processors, microprocessors, microcontrollers, digital signalprocessors, field programmable gate arrays (FPGAs), application specificintegrated circuits (ASICs), graphics processing units (GPUs), tensorprocessing units (TPUs), and/or the like in computing device 100.Computing device 100 may be implemented as a stand-alone subsystem, as aboard added to a computing device, and/or as a virtual machine.

Memory 120 may be used to store software executed by computing device100 and/or one or more data structures used during operation ofcomputing device 100. Memory 120 may include one or more types ofmachine readable media. Some common forms of machine readable media mayinclude floppy disk, flexible disk, hard disk, magnetic tape, any othermagnetic medium, CD-ROM, any other optical medium, punch cards, papertape, any other physical medium with patterns of holes, RAM, PROM,EPROM, FLASH-EPROM, any other memory chip or cartridge, and/or any othermedium from which a processor or computer is adapted to read.

Processor 110 and/or memory 120 may be arranged in any suitable physicalarrangement. In some embodiments, processor 110 and/or memory 120 may beimplemented on a same board, in a same package (e.g.,system-in-package), on a same chip (e.g., system-on-chip), and/or thelike. In some embodiments, processor 110 and/or memory 120 may includedistributed, virtualized, and/or containerized computing resources.Consistent with such embodiments, processor 110 and/or memory 120 may belocated in one or more data centers and/or cloud computing facilities.

As shown, memory 120 includes a classification module 130, a predictionmodule 140, and a correction module 150 that may be used to implementand/or emulate the prediction-correction based zero shot learning forclassification systems and models described further herein and/or toimplement any of the methods described further herein. In some examples,classification module 130 may be used to receive an image 160 and toclassify image 160 into one of a known set of classes and to provide theresults as a classification 180 as is described in further detail below.In some examples, prediction module 140 and correction module 150 may beused to receive a class label 170 (e.g., a description) of a new classthat may be used to provide classification module 130 with the abilityto classify images 160 into that new class without having to be trainedbased on images from the new class as is described in further detailbelow. In some examples, one or more of classification module 130,prediction module 140, and/or correction module 150 may be trained basedon training samples that include a set of images 160, class labels 170,and ground truth classifications for each of the training samples as isdescribed in further detail below. In some examples, prediction module140 and correction module 150 may be collectively referred to as acorrection network. In some examples, prediction module 140 may beconsidered a task module because it is task specific in that it is usedto convert class labels 170 into a form usable by classification module130. In some examples, correction module 150 may be considered ametadata module as it performs the meta task of making correction to aprediction made by a task module (e.g., prediction module 140).

In some examples, one or more of classification module 130, predictionmodule 140, and/or correction module 150 may include a single- ormulti-layer neural network, where each layer of the neural networkimplements is activated according to Equation 1, where a is the output,x is the input to the neural network layer, W is a set of trainableweights, b is a set of trainable biases, and f is an activationfunction, such as identity, logistic, tanh, arctan, softsign, rectifiedlinear unit, leaky rectified linear unit, and/or the like. And althoughclassification module 130, prediction module 140, and correction module150 are depicted as a software modules, classification module 130,prediction module 140, and correction module 150 may be implementedusing hardware, software, and/or a combination of hardware and software.

a=f(Wx+b)   Equation 1

FIG. 2 is a simplified diagram of a method 200 for zero shot learningusing a prediction-correction approach according to some embodiments.One or more of the processes 210-280 of method 200 may be implemented,at least in part, in the form of executable code stored onnon-transitory, tangible, machine-readable media that when run by one ormore processors may cause the one or more processors to perform one ormore of the processes 210-280. In some embodiments, method 200 may beused to augment a classifier (e.g., classification module 130) toclassify exemplars from a new class for which the classifier has notbeen previously trained. In some examples, method 200 may use aprediction module (e.g., prediction module 140) and a correction module(e.g., correction module 150) to provide a corrected prediction of acluster center for the new class that is usable by the prediction moduleto classify the exemplars for the new class.

Method 200 is described below in reference to the examples ofembodiments for implementing classification module 130, predictionmodule 140, and correction module 150 as shown in FIGS. 3A, 3B, and 4.However, it is understood that the embodiments of FIGS. 3A, 3B, and 4are exemplary only and other structures and/or arrangements of themodules are possible for use with method 200.

At a process 210, training data is received. In some examples, thetraining data includes training samples for a plurality of previouslyrecognized classes, which are sometimes referred to as the “seen”classes. Each of the training samples include an image (e.g., image 160)to be classified, a class label (e.g., class label 170) describing theclass to which the image belongs, and a ground truth classification forthe image. Each of the class labels in the training sample for aparticular class is the same. In some examples, the class label may bethe same as the ground truth classification. FIG. 5 is a simplifieddiagram of training data for a class according to some embodiments.Class label 510 shows a class label for the class of birds “MangroveCuckoo.” As shown, class label 510 is a natural language description ofmangrove cuckoos and includes descriptive text that may be visuallyapparent in an image such as “a long tail,” “brown above,”“black-and-white below,” “black curved bill”, etc. FIG. 5 further showsthree examples of training images 520, 530, and 540 of the mangrovecuckoo. As further shown in FIG. 5, individual training images (andimages used after training), such as training images 520, 530, and/or540, may not include visual examples of each of the visual featuresincluded in the textual description of class label 510. Thus, theexamples of FIG. 5 depict three training samples for the class mangrovecuckoo: class label 510, image 520, and ground truth class mangrovecuckoo; class label 510, image 530, and ground truth class mangrovecuckoo; and class label 510, image 540, and ground truth class mangrovecuckoo. In some examples, the training data may be obtained from one ormore training datasets, such as the Caltech UCSD Birds 2011 (CUB)dataset, the North America Birds (NAB), dataset, and/or the like. TheCUB dataset is described in further detail in C. Wah, et al., “TheCaltech-UCSD Birds-200-2011 Dataset. Technical Report CNS-TR-2011-001,”California Institute of Technology, 2011, which is incorporated byreference. The NAB dataset is described in further detail in G. VanHorn, et al., “Building a Bird Recognition App and Large Scale Datasetwith Citizen Scientists: The Fine Print in Fine-grained DatasetCollection,” Proceedings of the IEEE Conference on Computer Vision andPattern Recognition, pp. 595-604, 2015, which is incorporated byreference.

Referring back to FIG. 2, at a process 220, the training data ispartitioned by class. The partitioning separates the training datareceiving during process 210 into two disjoint sets. A first orprediction set includes the training samples for a first subset of theclasses from the training data that will be subsequently used to trainthe prediction module. A second or correction set includes the trainingsamples for each of the classes not included in the first subset ofclasses (e.g., the training data for the classes not used to train theprediction module). For example, if the training data includes trainingdata for M+N classes, the training data for M of the classes form theprediction set and the training data for N of the classes form thecorrection set, where none of the M classes are the same as any of the Nclasses. In some examples, the number M corresponds to between 40 and 90percent of the total M+N classes from the training data received duringprocess 210.

At a process 230, the prediction module (e.g., prediction module 140) istrained using the prediction set. The training of process 230 isdescribed with respect to prediction module 140 as shown in FIG. 3A,which is a simplified diagram of prediction module 140 during trainingaccording to some embodiments. More specifically, prediction module 140includes a text encoder 310, an image encoder 320, and a predictionnetwork 330.

As shown, text encoder 310 receives a class label 342 for the currentsample and encodes class label 342 into a natural language featurevector capturing the semantics of class label 342. In some examples,text encoder 310 may encode each of the words in class label 342 usingthe GloVe encodings where each word is encoded as an element of R³⁰⁰. Insome examples, text encoder 310 may encode each of the words using thecharacter n-gram encodings where each word is encoded as an element ofR¹⁰⁰. In some examples, the encoding of each word is based on aconcatenation of GloVe and character n-gram encodings. In some examples,when there is no GloVe and/or character n-gram encoding for a word(e.g., the word is not in English), a random encoding is selected from aNormal distribution having a mean and standard deviation that is thesame as the GloVe encodings (e.g., mean of zero and standard deviationof 0.4), with the same random encoding used consistently for eachoccurrence of the respective word. In some examples, when there is noGloVe and/or character n-gram encoding for a word (e.g., the word is notin English) a value of zero is used. In some examples, the text encodingmay include using a term frequency-inverse document frequency (TF-IDF)approach where the words are reduced to their stem words and thentokenized before the TF-IDF is calculated. Use of TF-IDF for textencoding is described in further detail in Zhu, et al., “A GenerativeAdversarial Approach for Zero-shot Learning from Noisy Texts,” IEEEConference on Computer Vision and Pattern Recognition, 2018, which isincorporated by reference.

As further shown, image encoder 320 receives an image 344 and encodesimage 344 into an image feature vector capturing characteristic featuresof image 344, such as colors, shapes, relative sizes, and/or the like.In some examples, image encoder 320 may be based on a residual networkarchitecture, which are described in more detail in He, et al., “DeepResidual Learning for Image Recognition,” IEEE Conference on ComputerVision and Pattern Recognition, 2016, which is incorporated by referenceherein. In some examples, image encoder 320 may be built around acomputer vision library, such as the Open Source Computer VisionLibrary. In some examples, image encoder 320 is optional and may beomitted when the image feature vectors for each of the images areincluded in the training data received during process 210.

Prediction network 330 receives the natural language feature vector fromtext encoder 310 and the image feature vector from image encoder 320 andpredicts a cluster center {circumflex over (μ)} 346 for the class towhich class label 342 and image 344 belongs. In some examples,prediction network 330 may include a single- or multi-layer neuralnetwork, where each layer of the neural network implements is activatedaccording to Equation 1.

In some examples, prediction network 330 may be trained by repeatedlypresenting each of the training samples in the prediction set untilprediction network 330 converges to an acceptable error, a thresholdnumber of training samples are presented, a threshold number of trainingepochs occur, and/or the like. In some examples, prediction network 330may be trained with unsupervised learning where the cluster centers foreach of the classes represented in the prediction set are learnedwithout comparing the predicted cluster centers {circumflex over (μ)}346 against the ground truth cluster centers for each of the classes,such as by using a self-organizing feature map approach. In someexamples, prediction network 330 may be trained with supervised learningby comparing the predicted cluster centers {circumflex over (μ)} 346against the ground truth cluster centers for each of the classes, suchas by using the stochastic gradient descent training algorithm and backpropagation. In some examples, the loss function may be based on thedistance between each predicted cluster center {circumflex over (μ)} 346and the corresponding ground truth cluster center for that class asshown in Equation 2, where d indicates the Euclidean or L2 norm distancebetween a predicted cluster center {circumflex over (μ)} 346 and acorresponding ground truth cluster centerμ and E is the expected valueacross all the training samples. In some examples, the loss function mayfurther include a sparsity regularization term as shown in Equation 3,where α is a coefficient of regularization and W represents the weightsfor the various neurons in the prediction module, and ∥ ∥² is the L2norm. In some examples, the sparsity regularization term may be used tokeep the values of the weights low, which helps address overfittingduring the training. In some examples, α may be selected in the rangefrom 10⁻⁴ to 10⁻². In some examples, the training may further usedropout to avoid overfitting.

L _(predict) =E[d({circumflex over (μ)}, μ)]   Equation 2

L _(predict) =E[d({circumflex over (μ)}, μ)] +α∥W∥ ²   Equation 3

Referring back to FIG. 2, at a process 240, the correction module (e.g.,correction module 150) is trained using the correction set. The trainingof process 240 is described with respect to prediction module 140 andcorrection module 150 as shown in FIG. 3B, which is a simplified diagramof correction module 150 during training according to some embodiments.More specifically, correction module 150 includes a correction network370.

As shown, text encoder 310 of prediction module 140 receives a classlabel 352 for one of the classes from the training samples in thecorrection set. Because the classes in the correction set are notincluded in the prediction set, class label 352 corresponds to a classlabel that prediction module 140 was not trained against. Class label352 is encoded into a natural language feature vector that is passed toprediction network 330, which makes a prediction as to the likelycluster center {circumflex over (μ)} 356 for the class corresponding toclass label 352 and does so without access to any of the images andimage feature vectors corresponding to class label 352. Thus, classlabel 352 is zero-shot with respect to prediction network 330 duringprocess 240.

Correction network 370 receives the natural language feature vector fromtext encoder 310, the predicted cluster center {circumflex over (μ)} 356from prediction network 330, and class labels encodings 358 (e.g.,natural language feature vectors as encoded by text encoder 310)corresponding to each of the class labels 342 from the prediction setand used to train prediction module 140 during process 230. Providingthe class labels encodings 358 from the prediction set to correctionnetwork 370 allows correction network 370 to observe differences betweenthe natural language feature vector for class label 352 and theprediction network class label encodings 358 to determine howsemantically different class label 352 is from the class labels used totrain prediction module 140. This information is used by correctionnetwork 370 to provide a correction ϵ 380 to the predicted clustercenter {circumflex over (μ)} 356 for class label 352. In some examples,the sum of the predicted cluster center {circumflex over (μ)} 356 andcorrection ϵ 380 provides an improved prediction for the cluster centerfor the class corresponding to class label 352. In some examples,correction network 370 may include a single- or multi-layer neuralnetwork, where each layer of the neural network implements is activatedaccording to Equation 1.

In some examples, correction network 370 may be trained by repeatedlypresenting each of the training samples in the correction set untilcorrection network 370 converges to an acceptable error, a thresholdnumber of training samples are presented, a threshold number of trainingepochs occur, and/or the like. In some examples, correction network 370may be trained with supervised learning by comparing the predictedcluster centers {circumflex over (μ)} 356 as corrected by respectivecorrections ϵ 380 against the ground truth cluster centers for each ofthe classes corresponding to the class labels 352 in the correction set,such as by using the stochastic gradient descent training algorithm andback propagation. In some examples, the loss function may be based onthe distance between each predicted cluster center {circumflex over (μ)}356 as corrected by correction ϵ 380 and the corresponding ground truthcluster center for that class as shown in Equation 4, where d indicatesthe Euclidean or L2 norm distance between a correction ϵ 380 and thedifferences between a predicted cluster center {circumflex over (μ)} 346and a corresponding ground truth cluster center μ and E is the expectedvalue across all the training samples. In some examples, the trainingmay further use dropout to avoid overfitting.

L _(correct) =E[d(ϵ,μ−{circumflex over (μ)})]   Equation 4

Referring back to FIG. 2, at a process 250, a class label for a newclass is applied to the prediction module. The application of process250 is described with respect to prediction module 140 as shown in FIG.4, which is a simplified diagram of classification system during useaccording to some embodiments.

As shown, text encoder 310 of prediction module 140 receives a new classlabel 410 for a class that is not represented in either the classes fromtraining samples from the prediction set or the training samples fromthe correction set. Thus, new class label 410 is zero-shot forprediction module 140 because prediction module 140 has never previouslyseen new class label 410. New class label 410 is encoded into a naturallanguage feature vector that is passed to prediction network 330, whichmakes a prediction as to the likely cluster center {circumflex over (μ)}420 for the class corresponding to new class label 410 and does sowithout access to any of the images and image feature vectorscorresponding to new class label 410 because no such training imageshave to be available.

Referring back to FIG. 2, at a process 260, the new class label isapplied to the correction module. As shown in FIG. 4, correction network370 of correction module 150 receives the predicted cluster center{circumflex over (μ)} 420 for the class corresponding to new class label410, the natural language feature vector from text encoder 310corresponding to new class label 410, and class labels encodings used totrain prediction network 330. Because new class label 410 corresponds toa class that is not represented in either the classes from trainingsamples from the prediction set or the training samples from thecorrection set, new class label 410 is zero-shot for correction module150 because correction module 150 has never previously seen new classlabel 410. Correction network 370 then generates a correction ϵ 380 tothe predicted cluster center {circumflex over (μ)} 420. Correction E 380and the predicted cluster center {circumflex over (μ)} 420 are passed toa summing unit 440 (e.g., an adder), which generates a new class clustercenter {circumflex over (μ)} 450.

Referring back to FIG. 2, at a process 270, the new class is added tothe classification module (e.g., classification module 130). As furthershown in FIG. 4, classification module 130 includes a classifier 460.Classifier receives new class cluster center μ 450 and adds new classcluster center μ 450 to its list of cluster centers for classesclassification module 130 is able to classify. In some examples, thelist of cluster centers includes cluster centers for each of the otherclasses that classification module is able to classify. In someexamples, the list of cluster centers includes some or all of thecluster centers for the classes in the prediction set and/or thecorrection set.

Referring back to FIG. 2, at a process 280, an image is classified usingthe classification module. As further shown in FIG. 4, classificationmodule 130 includes an image encoder 470 in addition to the previouslydescribed classifier 460. Similar to image encoder 320, image encoder470 receives an image 480 and encodes image 480 as an image featurevector. In some examples, image encoder 470 is the same as image encoder320. The image feature vector is then passed to classifier 460, whichpredicts a classification 490 for image 480. In some examples,classifier 460 compares the image feature vector for image 480 to eachof the cluster centers in its list of cluster centers and generatesclassification 490 as the class whose cluster center is closest to theimage feature vector corresponding to image 480. In some examples,classifier 460 may further provide a confidence in classification 490based on the distance between the cluster center corresponding toclassification 490 and the image feature vector corresponding to image480. In some examples, classifier 460 may indicate that there is noclassification when the distance is greater than a threshold.Advantageously, classification module 130 is able to classify image 480into classes for which it has never previously seen an image, such asthe class corresponding to new class label 410 because it has beenaugmented using process 270.

As discussed above and further emphasized here, FIGS. 2-4 are merelyexamples which should not unduly limit the scope of the claims. One ofordinary skill in the art would recognize many variations, alternatives,and modifications. According to some embodiments, method 200,classification module 130, prediction module 140, and correction module150 may be adapted to classification problems other than imageclassification. In some examples, image encoders 320 and/or 470 may bereplaced with encoders for generating feature vectors for a differentclassification domain.

According to some embodiments, method 200 may be modified to increasethe number of training examples that are presented to the correctionmodule during process 240. In some examples, processes 220 and 230 maybe repeated multiple times where different partitions are used togenerate the prediction and correction sets. For example, if thetraining data included three classes A, B, and C and the partitioning ofprocess 220 puts two classes in the prediction set and one class in thecorrection set, training samples for process 240 may be generated bytraining a first version of the prediction module with classes A and Bin the prediction set and class C in the correction set, a secondversion of the prediction module may be trained with classes A and C inthe prediction set and class B in the correction set, and a thirdversion of the prediction module may be trained with classes B and C inthe prediction set and class A in the correction set. In some examples,the number of different partitions may be fewer than the full number ofpossible partitions with the choice of partitions being selectedrandomly. In some examples, different partitions may partition differentnumbers of classes into different prediction sets. In some examples,with each of the different partitions, a partition-specific predictionmodule is trained during process 230 and then the partition-specificmodule is used in the training of a same correction module duringprocess 240 (e.g., each of the different partitions is used to furthertrain the same correction module trained using the previously trainedpartitions). In some examples, each of the partition-specific trainingmodules is saved along with its prediction accuracy so that a best oneof the partition-specific training modules may be used as the predictionmodule during process 250.

According to some embodiments, the training of the prediction moduleduring process 230 may be enhanced by factoring in classification errordue to the predicted cluster centers {circumflex over (μ)} 346. In someexamples, the predicted cluster centers {circumflex over (μ)} 346 may beused to classify the training images (e.g., by using the predictedcluster centers {circumflex over (μ)} 346 with classification module130) and the classification error may be back propagated to provideadditional training for the weights and/or biases of prediction network330.

The classification accuracy of classification module 130 using the zeroshot classes identified by prediction module 140 and correction module150 in comparison to other zero shot learning approaches is evaluated asdescribed below for data from both the CUB and NAB datasets. To morefully evaluate the accuracy of the class centers provided by predictionmodule 140 and correction module 150, the CUB and NAB datasets aredivided according to two splits that control which classes are “seen”and used to train prediction module 140 and correction module 150 andthose classes that are “unseen” during training and used to add newcluster centers to classification module 130 using processes 250-270. Afirst split uses a super category shared (SCS) strategy where classesfrom each super category (e.g., wrens, sparrows, etc.) are included inboth the “seen” and “unseen” data (e.g., house wren may be in the “seen”data and mountain wren may be in the “unseen” data). A second split useda super category exclusive (SCE) strategy where classes from each supercategory are include in either the “seen” data or the “unseen” data, butnot in both. The SCS and SCE strategies are described in further detailin M. Elhoseiny, et al., “Write a Classifier: Predicting VisualClassifiers from Unstructured Text,” IEEE Transactions on PatternAnalysis and Machine Intelligence, 39(12):2539-2553, 2017, which isincorporated by reference.

The other zero shot learning approaches include MCZSL described in Z.Akata, et al., Multi-Cue Zero-Shot Learning with Strong Supervision,”Proceedings of the IEEE Conference on Computer Vision and PatternRecognition, pp. 59-68, 2016; WAC-Linear described in M. Elhoseiny, etal. “Write a Classifier: Zero-Shot Learning using Purely TextualDescriptions,” IEEE International Conference on Computer Vision (ICCV),pp. 2584-2591, 2013; WAC-Kernel and ZSLPP described in M. Elhoseiny, etal., “Write a Classifier: Predicting Visual Classifiers fromUnstructured Text,” IEEE Transactions on Pattern Analysis and MachineIntelligence, 39(12):2539-2553, 2017; ESZSL described in B.Romera-Paredes, et al. “An Embarrassingly Simple Approach to Zero-ShotLearning,” International Conference on Machine Learning, pp. 2152-2161,2015; SJE described in Z. Akata, et al., “Evaluation of OutputEmbeddings for Fine-grained Image Classification,” IEEE Conference onComputer Vision and Pattern Recognition, pp. 2927-2936, 2015; ZSLNSdescribed in R. Qiao, et al., “Less is More: Zero-Shot Learning fromOnline Textual Documents with Noise Suppression,” Proceedings of theIEEE Conference on Computer Vision and Pattern Recognition, pp.2249-2257, 2016; SynCfast and SynCovo described in S. Changpinyo, etal., “Synthesized Classifiers for Zero-Shot Learning,” IEEE Conferenceon Computer Vision and Pattern Recognition, pp. 5327-5336, 2016; andGAZSL described in Y. Zhu, et al., “A Generative Adversarial Approachfor Zero-Shot Learning from Noisy Texts,” IEEE Conference on ComputerVision and Pattern Recognition, 2018, each of which is incorporated byreference.

FIG. 6 is a simplified diagram of classification accuracy against datafrom new classes according to some embodiments. As shown in FIG. 6, theclassification accuracy of classification module 130 as updated by newclass cluster centers as predicted by prediction module 140 andcorrected by correction module 150 using method 200 (“CorrectionNetworks”) are shown in comparison against classification accuracies ofthe other zero shot learning approaches. The classification accuracy isshown for both the CUB and NAB datasets using both the SCS and SCEsplits for images drawn from the “unseen” classes (e.g., images forthose classes whose cluster centers were added by process 270 and werenot included in the training data from processes 230 and 240). Theaccuracy metric used is the area under the seen-unseen curve (AUSUC),which is a measure of how well each of the trained classifiers minimizesthe 0-1 loss function (e.g., did the classification module correctlyclassify the images). The AUSUC metric is described in W. Chao, et al.,“An Empirical Study and Analysis of Generalized Zero-Shot Learning forObject Recognition in the Wild,” European Conference on Computer Vision,pp. 52-68, 2016, which is incorporated by reference. As can be seen inFIG. 6, classification module 130 as updated by the correction networkof prediction module 140 and correction module 150 outperformed all theother zero shot learning approaches for both the CUB and NAB datasetsusing both the SCS and SCE splits with the exception of the GAZSLapproach on the CUB dataset with the SCE split, which only slightlyout-performed classification module 130.

FIG. 7 is a simplified diagram of classification accuracy against datafrom both trained and new classes according to some embodiments. Asshown in FIG. 6, the classification accuracy of classification module130 as updated by new class cluster centers as predicted by predictionmodule 140 and corrected by correction module 150 using method 200(“Correction Net”) are shown in comparison against classificationaccuracies of the other zero shot learning approaches. Theclassification accuracy is shown for the CUB dataset using both the SCSand SCE splits for images drawn from both the “seen” and the “unseen”classes (e.g., images for those classes whose cluster centers were addedby process 270 and images for those classes included in the trainingdata from processes 230 and 240). The accuracy metric used is the AUSUCmetric. As can be seen in FIG. 7, classification module 130 as updatedby the correction network of prediction module 140 and correction module150 outperformed all the other zero shot learning approaches for the CUBdataset using both the SCS and SCE splits.

FIG. 8 is a simplified diagram of the impact of various factors onclassification accuracy according to some embodiments. FIG. 8 shows thatusing the correction module to correct the cluster center prediction ofthe prediction module results in a two point increase in the AUSUCmetric relative to using only the prediction module to predict the newcluster center. FIG. 8 also shows that providing the correction modulewith the class label encodings 358 of the classes used to train theprediction module improves the AUSUC metric by 2.4 points.

Some examples of computing devices, such as computing device 100 mayinclude non-transitory, tangible, machine readable media that includeexecutable code that when run by one or more processors (e.g., processor110) may cause the one or more processors to perform the processes ofmethod 200 and/or emulate the structures of FIGS. 3A, 3B, and/or 4. Somecommon forms of machine readable media that may include the processes ofmethod 200 and/or emulate the structures of FIGS. 3A, 3B, and/or 4 are,for example, floppy disk, flexible disk, hard disk, magnetic tape, anyother magnetic medium, CD-ROM, any other optical medium, punch cards,paper tape, any other physical medium with patterns of holes, RAM, PROM,EPROM, FLASH-EPROM, any other memory chip or cartridge, and/or any othermedium from which a processor or computer is adapted to read.

This description and the accompanying drawings that illustrate inventiveaspects, embodiments, implementations, or applications should not betaken as limiting. Various mechanical, compositional, structural,electrical, and operational changes may be made without departing fromthe spirit and scope of this description and the claims. In someinstances, well-known circuits, structures, or techniques have not beenshown or described in detail in order not to obscure the embodiments ofthis disclosure Like numbers in two or more figures represent the sameor similar elements.

In this description, specific details are set forth describing someembodiments consistent with the present disclosure. Numerous specificdetails are set forth in order to provide a thorough understanding ofthe embodiments. It will be apparent, however, to one skilled in the artthat some embodiments may be practiced without some or all of thesespecific details. The specific embodiments disclosed herein are meant tobe illustrative but not limiting. One skilled in the art may realizeother elements that, although not specifically described here, arewithin the scope and the spirit of this disclosure. In addition, toavoid unnecessary repetition, one or more features shown and describedin association with one embodiment may be incorporated into otherembodiments unless specifically described otherwise or if the one ormore features would make an embodiment non-functional.

Although illustrative embodiments have been shown and described, a widerange of modification, change and substitution is contemplated in theforegoing disclosure and in some instances, some features of theembodiments may be employed without a corresponding use of otherfeatures. One of ordinary skill in the art would recognize manyvariations, alternatives, and modifications. Thus, the scope of theinvention should be limited only by the following claims, and it isappropriate that the claims be construed broadly and in a mannerconsistent with the scope of the embodiments disclosed herein.

What is claimed is:
 1. A method of training a classifier, the methodcomprising: receiving a set of training data including training samplesfrom a plurality of classes; partitioning the training data according toa first partition into a first set and a second set of training data,wherein classes for training samples in the first set are not in thesecond set and training samples from the second set are not in the firstset, each training sample including a class label, an exemplar of inputdata, and a ground truth classification; training a prediction modulebased on the training samples in the first set to predict a clustercenter based on a class label; training a correction module based on thetraining samples in the second set and each of the class labels in thefirst set to generate a correction to the cluster center predicted bythe prediction module; presenting a class label for a new class to theprediction module to predict a cluster center for the new class, the newclass being different from each class whose training samples are in boththe first set and the second set; presenting the class label for the newclass, the predicted cluster center for the new class, and each of theclass labels in the first set to the correction module to generate acorrection for the predicted cluster center for the new class;correcting the cluster center for the new class based on the predictedcluster center for the new class and the correction for the predictedcluster center for the new class; augmenting a classifier based on thecorrected cluster center for the new class; and classifying input datainto the new class using the augmented classifier.
 2. The method ofclaim 1, wherein: the classifier is an image classifier; and the inputdata is an image.
 3. The method of claim 1, wherein each of the classlabels is a natural language class label.
 4. The method of claim 1,wherein the prediction module includes a text encoder and a predictionnetwork.
 5. The method of claim 4, wherein the prediction module furtherincludes an image encoder.
 6. The method of claim 4, wherein: theprediction network includes a neural network; and training theprediction network comprises using supervised learning based on groundtruth cluster centers for each of the classes in the first set.
 7. Themethod of claim 1, wherein: the correction module includes a neuralnetwork; and training the correction module comprises using supervisedlearning based on ground truth cluster centers for each of the classesin the second set.
 8. The method of claim 1, wherein correcting thecluster center for the new class label comprises adding the predictedcluster center for the new class label to the correction for thepredicted cluster center for the new class label.
 9. The method of claim1, wherein classifying the input data into the new class comprises:encoding the input data to form a feature vector; and comparing adistance between the feature vector and the corrected cluster center forthe new class label.
 10. The method of claim 1, further comprising:partitioning the training data according to a second partition differentfrom the first partition into a third set and a fourth set, whereinclasses for training samples in the third set are not in the fourth setand training samples from the fourth set are not in the third set;training a second prediction network based on the training samples inthe third set; and further training the correction network based on thetraining samples in the fourth set and each of the class labels in thethird set.
 11. A system comprising: a prediction module for predicting acluster center from a class label; a correction module for correctingthe predicted cluster center for the class label; and a classificationmodule for classifying input data into a class corresponding to theclass label; wherein: the prediction module is trained based on trainingdata from a first set, the first set comprising training samples for aplurality of first classes; the correction module is trained based ontraining data from a second set, the second set comprising trainingsamples for a plurality of second classes, wherein none of the firstclasses is in the second classes and none of the second classes is inthe first class; the prediction module is used to predict a new clustercenter for a new class label corresponding to a class that is not in thefirst classes and not in the second classes; the correction module isused to correct the predicted new cluster center; and the classificationmodule is augmented based on the corrected new cluster center so thatthe classification module is able to classify the input data into theclass corresponding to the new class label.
 12. The system of claim 11,wherein: the classifier is an image classifier; the input data is animage; each of the class labels is a natural language class label; andthe prediction module includes a text encoder and a prediction network.13. The system of claim 12, wherein: the prediction network includes aneural network; and the prediction network is further trained usingsupervised learning based on ground truth cluster centers for each ofthe classes in the first set.
 14. The system of claim 11, wherein: thecorrection module includes a neural network; and the correction moduleis further trained using supervised learning based on ground truthcluster centers for each of the classes in the second set.
 15. Thesystem of claim 11, further comprising a summing unit for adding thepredicted cluster center for the new class label to the correction forthe predicted cluster center for the new class label.
 16. Anon-transitory machine-readable medium comprising executable code whichwhen executed by one or more processors associated with a computingdevice are adapted to cause the one or more processors to perform amethod comprising: receiving a set of training data including trainingsamples from a plurality of classes; partitioning the training dataaccording to a first partition into a first set and a second set oftraining data, wherein classes for training samples in the first set arenot in the second set and training samples from the second set are notin the first set, each training sample including a class label, anexemplar of input data, and a ground truth classification; training aprediction module based on the training samples in the first set topredict a cluster center based on a class label; training a correctionmodule based on the training samples in the second set and each of theclass labels in the first set to generate a correction to the clustercenter predicted by the prediction module; presenting a class label fora new class to the prediction module to predict a cluster center for thenew class, the new class being different from each class whose trainingsamples are in both the first set and the second set; presenting theclass label for the new class, the predicted cluster center for the newclass, and each of the class labels in the first set to the correctionmodule to generate a correction for the predicted cluster center for thenew class; correcting the cluster center for the new class based on thepredicted cluster center for the new class and the correction for thepredicted cluster center for the new class; augmenting a classifierbased on the corrected cluster center for the new class; and classifyinginput data into the new class using the augmented classifier.
 17. Thenon-transitory machine-readable medium of claim 16, wherein: theclassifier is an image classifier; the input data is an image. each ofthe class labels is a natural language class label; and the predictionmodule includes a text encoder and a prediction network.
 18. Thenon-transitory machine-readable medium of claim 17, wherein: theprediction network includes a neural network; and training theprediction network comprises using supervised learning based on groundtruth cluster centers for each of the classes in the first set.
 19. Thenon-transitory machine-readable medium of claim 16, wherein: thecorrection module includes a neural network; and training the correctionmodule comprises using supervised learning based on ground truth clustercenters for each of the classes in the second set.
 20. Thenon-transitory machine-readable medium of claim 16, wherein correctingthe cluster center for the new class label comprises adding thepredicted cluster center for the new class label to the correction forthe predicted cluster center for the new class label.